package com.bob.shirodemo.base.shiro;

import org.apache.shiro.authc.AuthenticationException;
import org.apache.shiro.authc.AuthenticationInfo;
import org.apache.shiro.authc.AuthenticationToken;
import org.apache.shiro.authz.AuthorizationException;
import org.apache.shiro.authz.Permission;
import org.apache.shiro.mgt.SecurityManager;
import org.apache.shiro.session.Session;
import org.apache.shiro.session.SessionException;
import org.apache.shiro.session.mgt.SessionContext;
import org.apache.shiro.session.mgt.SessionKey;
import org.apache.shiro.subject.PrincipalCollection;
import org.apache.shiro.subject.Subject;
import org.apache.shiro.subject.SubjectContext;

import java.util.Collection;
import java.util.List;

public class MySecurityManager implements SecurityManager {
    @Override
    public Subject login(Subject subject, AuthenticationToken authenticationToken) throws AuthenticationException {
        return null;
    }

    @Override
    public void logout(Subject subject) {

    }

    @Override
    public Subject createSubject(SubjectContext subjectContext) {
        return null;
    }

    @Override
    public AuthenticationInfo authenticate(AuthenticationToken authenticationToken) throws AuthenticationException {
        return null;
    }

    @Override
    public boolean isPermitted(PrincipalCollection principalCollection, String s) {
        return false;
    }

    @Override
    public boolean isPermitted(PrincipalCollection principalCollection, Permission permission) {
        return false;
    }

    @Override
    public boolean[] isPermitted(PrincipalCollection principalCollection, String... strings) {
        return new boolean[0];
    }

    @Override
    public boolean[] isPermitted(PrincipalCollection principalCollection, List<Permission> list) {
        return new boolean[0];
    }

    @Override
    public boolean isPermittedAll(PrincipalCollection principalCollection, String... strings) {
        return false;
    }

    @Override
    public boolean isPermittedAll(PrincipalCollection principalCollection, Collection<Permission> collection) {
        return false;
    }

    @Override
    public void checkPermission(PrincipalCollection principalCollection, String s) throws AuthorizationException {

    }

    @Override
    public void checkPermission(PrincipalCollection principalCollection, Permission permission) throws AuthorizationException {

    }

    @Override
    public void checkPermissions(PrincipalCollection principalCollection, String... strings) throws AuthorizationException {

    }

    @Override
    public void checkPermissions(PrincipalCollection principalCollection, Collection<Permission> collection) throws AuthorizationException {

    }

    @Override
    public boolean hasRole(PrincipalCollection principalCollection, String s) {
        return false;
    }

    @Override
    public boolean[] hasRoles(PrincipalCollection principalCollection, List<String> list) {
        return new boolean[0];
    }

    @Override
    public boolean hasAllRoles(PrincipalCollection principalCollection, Collection<String> collection) {
        return false;
    }

    @Override
    public void checkRole(PrincipalCollection principalCollection, String s) throws AuthorizationException {

    }

    @Override
    public void checkRoles(PrincipalCollection principalCollection, Collection<String> collection) throws AuthorizationException {

    }

    @Override
    public void checkRoles(PrincipalCollection principalCollection, String... strings) throws AuthorizationException {

    }

    @Override
    public Session start(SessionContext sessionContext) {
        return null;
    }

    @Override
    public Session getSession(SessionKey sessionKey) throws SessionException {
        return null;
    }
}
